<template>
    <div v-if="loading">
      loading....
    </div>
</template>

<script lang="ts">
import { Vue, Component} from 'vue-property-decorator'
@Component
export default class Loading extends Vue{
  //data 实例属性
  loading: boolean=false

  //methods方法 = 类的实例方法
  start():void{
    this.loading = true
  }
  finish():void{
    this.loading = false
  }

}
</script>

<style scoped >

</style>
